cat $1 | while read line
do
line1=${line%%_*}
line2=${line##*_}
export BAM_DIR=/mnt/md1200/6/yjp/5hmc_analysis_hg19_new/bam_file
export normal_bam=$BAM_DIR/${line1}.bam
export tumor_bam=$BAM_DIR/${line2}.bam
export output=varscan/${line1}_${line2}
export reference="/mnt/md1200/6/yjp/genome/ucsc/hg19.fa"
export normal_pileup="samtools mpileup -q 1 -f $reference $normal_bam"
export tumor_pileup="samtools mpileup -q 1 -f $reference $tumor_bam"
nohup bash -c "java -jar /mnt/md1200/6/zhaocunyou/Programs/Varscan/VarScan.v2.3.6.jar somatic <($normal_pileup) <($tumor_pileup) $output --min-var-freq 0.01 --min-coverage 1" 2>&1 >varscan.log &
done
